import request from '@/utils/request'

export function login(data) {
  return request({
    url: '/login',
    method: 'post',
    data
  })
}
export function register(data) {
  return request({
    url: '/register',
    method: 'post',
    data
  })
}

// user
export function getUserPage(data) {
  return request({
    url: '/user/page',
    method: 'post',
    data: data
  })
}
export function deleteUser(data) {
  return request({
    url: '/user/delete',
    method: 'post',
    params: data
  })
}
export function addUser(data) {
  return request({
    url: '/user/add',
    method: 'post',
    data: data
  })
}
export function modifyUser(data) {
  return request({
    url: '/user/modify',
    method: 'post',
    data: data
  })
}
